package com.weather.service;

import com.weather.domain.Data;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.io.IOException;

/**
 * @author: htc
 * @date: Created in 17:49 2018/5/4.
 */
@Service
public class WeatherReportServiceImpl implements WeatherReportService {
    @Resource
    private WeatherService weatherService;

    @Override
    public Data getWeatherByCityName(String cityName) throws InterruptedException, IOException, ClassNotFoundException {
        return weatherService.getWeather(cityName).getData();
    }
}
